<template>
    <div>
      <GpBaseTable primary-key="id" :columns="columns" :url="url" :params="getParams"
                   sync-data-url="/xcdhTrading/gpHistoryName/syncGpHistoryName" ></GpBaseTable>
    </div>
</template>

<script>
import http from "network/http";

export default {
  name: "GpHistoryName",
  data(){
    return {
      columns: [
        {
          "key": "tsCode",
          search: true ,
          op: 'LIKE',
          "title": "TS代码"
        },
        {
          "key": "name",
          search: true ,
          op: 'LIKE',
          "title": "证券名称"
        },
        {
          "key": "startDate",
          "title": "开始日期"
        },
        {
          "key": "endDate",
          "title": "结束日期"
        },
        {
          "key": "annDate",
          "title": "公告日期"
        },
        {
          "key": "changeReason",
          "title": "变更原因"
        }
      ],
      url: "/xcdhTrading/gpHistoryName/v2/listByPage"
    }
  },
  created() {
    this.getNewTradeDate()
  },
  methods:{
    getParams(){

    },
    getNewTradeDate(){
      http.post("/xcdhTrading/stock-info/newTradeDate").then(res=>{
        this.formData.tradeDate = res.data.tradeDate
        this.tradeDateCode = res.data.tradeDateCode
      })
    },
  }
}
</script>

<style scoped>

</style>
